#ifndef ABSTRACTCHROMOSOMEFACTORY_H_
#define ABSTRACTCHROMOSOMEFACTORY_H_

class Chromosome;

/**
  * Class that represents abstract chromosome factory.
  * @author Łukasz Szybka
  */
class AbstractChromosomeFactory
{
public:
    /**
      * Creates new chromosome with length AbstractChromosomeFactory::chromosomeLength
      * @return Chromosome pointer
      */
    virtual Chromosome* getNewChromosome();
    /**
      * Creates new chromosome
      * @param len Length of chromosome to create
      * @return Chromosome pointer
      */
    virtual Chromosome* getNewChromosome(int len) = 0;
    /**
      * Creates new chromosome using Chromosome::getNewChromosome() and
      * calls Chromosome::setRandom() to give random values
      * @return Chromosome pointer
      */
    virtual Chromosome* getNewRandomChromosome();
protected:
    /**
      * Constructor
      * @param _chromLen Value to set AbstractChromosomeFactory::chromosomeLength
      */
    AbstractChromosomeFactory(int _chromLen);

    /**
      * Determines length of chromosomes that will be created
      */
    int chromosomeLength;
};

#endif /*ABSTRACTCHROMOSOMEFACTORY_H_*/
